function [  ] = addSubFolderToPath( folder, order )
% Add Sub-Folder(s) to Path

if nargin == 1
    order = 1;
end

dirList = dir(folder);
dirList = dirList([dirList.isdir]);
dirList = dirList(3:end); % the 1st is '.' and the 2nd is '..'

nDir = size(dirList, 1);
if nDir > 0
    for iDir = 1:nDir
        dirName_i = [folder, '/', dirList(iDir).name];
        addpath(dirName_i);
    end
else
    % do nothing
end

end
